<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <link crossorigin="anonymous" integrity="sha512-6KY5s6UI5J7SVYuZB4S/CZMyPylqyyNZco376NM2Z8Sb8OxEdp02e1jkKk/wZxIEmjQ6DRCEBhni+gpr9c4tvA==" href="https://lib.baomitu.com/twitter-bootstrap/5.1.1/css/bootstrap.min.css" rel="stylesheet">
    <title>球星列表</title>
    <script crossorigin="anonymous" integrity="sha512-b3xr4frvDIeyC3gqR1/iOi6T+m3pLlQyXNuvn5FiRrrKiMUJK3du2QqZbCywH6JxS5EOfW0DY0M6WwdXFbCBLQ==" src="https://lib.baomitu.com/Chart.js/3.5.1/chart.js"></script>
</head>
<style>
    body{
        background-image: url("../img/00.jpg");
        background-repeat: no-repeat;
        background-size: 100% auto;
    }
    .wenzi3{
        color: white;
        text-align: center;
    }
    .ziti{
        color: #ededed;
        font-size: 20px;
    }
    .ziti1{
        color: #337ab7;
    }
</style>


<body>

<div class="container">

    <h3 class="ziti1">球队简介</h3>
    <!--  新增球星按钮-->
    <a th:href="@{/ballteams/new}" class="btn btn-primary btn-sm nb-3">新增球队</a>
    <a th:href="@{/}" class="btn btn-primary btn-sm nb-3">返回主页</a>
    <br>
    <table class="table table-bordered table-striped">
        <thead class="thead-dark">
        <tr>
            <th class="wenzi3">球队全称</th>
            <th class="wenzi3">所属城市</th>
            <th class="wenzi3">球队简介</th>
            <th class="wenzi3">动作</th>
        </tr>
        </thead>
        <tbody>
        <tr th:each="aBallteam : ${ballteams}">
            <td th:text="${aBallteam.name}" class="ziti"></td>
            <td th:text="${aBallteam.city}" class="ziti"></td>
            <td th:text="${aBallteam.synopsis}" class="ziti"></td>
            <td>
                <a th:href="@{/ballteams/update(id=${aBallteam.ballteamId})}" class="btn btn-info btn-sn">修改</a>
                <a th:href="@{/ballteams/delete(id=${aBallteam.ballteamId})}"
                   class="btn btn-danger btn-sn"
                   onclick="if (!(confirm('你确定删除这个球队吗')))return false"
                >删除</a>
            </td>
        </tr>

        </tbody>
    </table>
</div>
</body>
</html>